﻿using System;
using System.Text;

namespace Ex04.Menus.Delegates
{
    public class MainMenu
    {
        private SubMenu m_SubMenu;

        public MainMenu(string i_Title)
        {
            m_SubMenu = new SubMenu(i_Title, "Exit");
        }

        /// <summary>
        /// Shows the main menu.
        /// </summary>
        public void Show()
        {
            m_SubMenu.Select();
        }

        /// <summary>
        /// Adds a menu item to the main menu.
        /// </summary>
        /// <param name="i_MenuItem">The menu item to add.</param>
        public void AddMenuItem(IMenuItem i_MenuItem)
        {
            m_SubMenu.AddMenuItem(i_MenuItem);
        }
    }
}